﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<SCB.Presentation.Models.UICategoriesModels>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
    CategoriesList
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <div class="temp_7">
        <div class="title">
            <div class="fl">
            </div>
            <div class="fc">
                <%--<a href="<%: Url.RouteUrl("Default", new {controller ="Product", action ="CategoryDetail", id= Model.CategoryId}) %>"> <span>
                    <%: Model.CategoryTitle%></span></a>--%>
            </div>
            <div class="fr">
            </div>
        </div>
        <div class="content">
            <ul class="list_category">
                <%
                   
                    foreach (var model in Model.Subcategories)
                    {%>
                <li class="root"><a href="<%: Url.RouteUrl("Default", new {controller ="Category", action ="Display", id= model.Id}) %>">
                    <span>
                        <%:model.Name%></span> </a></li>
                <% 
                        foreach (var subCategory in model.Subcategories)
                        { %>
                <li class="fl"><a href="<%: Url.RouteUrl("Default", new {controller ="Product", action ="ProductsByCategory", id= subCategory.Id}) %>">
                    <%:subCategory.Name %></a></li>
                <%
                        }
                %>
                <%if (Model.Subcategories.ToList().IndexOf(model) < (Model.Subcategories.Count() - 1))
                  { %>
                <li class="break_module_line"></li>
                <%}
                  else
                  {%>
                <li class="break_module"></li>
                <%}
                    }%>
            </ul>
        </div>
        <div class="bottom">
            <div class="fl">
            </div>
            <div class="fr">
            </div>
        </div>
    </div>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="LeftPanel" runat="server">
    <%Html.RenderPartial("LeftPanelUserControl", Model.Categories); %>
    <div class="break_module">
    </div>
    <div class="temp_5">
        <div class="title">
            <div class="fl">
            </div>
            <div class="fc">
                <span>Top Search</span></div>
            <div class="fr">
            </div>
        </div>
        <div class="content">
            <div class="list_link">
                <ul>
                    <li><a href="#">test1</a></li>
                    <li><a href="#">test2</a></li>
                    <li><a href="#">test3</a></li>
                </ul>
            </div>
        </div>
        <div class="bottom">
            <div class="fl">
            </div>
            <div class="fr">
            </div>
        </div>
    </div>
</asp:Content>
